using System.Diagnostics.CodeAnalysis;
using System.Linq.Expressions;
using ZeroBlog.Core.Domains.Blog;

namespace ZeroBlog.Core.DomainServices.Posts;

public interface IPostDomainService
{
    Task AddAsync(Post domain);
    Task DeleteAsync(IList<long> ids);
    Task UpdateAsync(Post domain);
    Task<Post> GetAsync([NotNull] Expression<Func<Post, bool>> predicate);
    Task<(IList<Post>, int)> Query(string? keyword, int pageNumber, int pageSize);
}